package Entidades;


public class Coordenada {
	private int posX;
	private int posY;
	private int nroPlanta;
    
    public void setearPosicionX (int x){
    	this.posX = x;
    }
    
    public void setearPosicionY (int y){
    	this.posY = y;
    }
  
    public int obtenerPosicionX (){
    	return this.posX;
    }
    
    public int obtenerPosicionY (){
    	return this.posY;
    }
    
    public void setearNroPlanta (int nroP){
    	 this.nroPlanta = nroP;
    }
    
    public int obtenerNroPlanta (){
    	return this.nroPlanta;
    }
    
    @Override     
    public String toString(){ 
        return new String("(" + nroPlanta + ", " + posX + ", " + posY + ")"); 
         
    }

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + nroPlanta;
		result = prime * result + posX;
		result = prime * result + posY;
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Coordenada other = (Coordenada) obj;
		if (nroPlanta != other.nroPlanta)
			return false;
		if (posX != other.posX)
			return false;
		if (posY != other.posY)
			return false;
		return true;
	}

}
